﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;
using System.Threading.Tasks;
using Zhao.Common.Helper;
using Zhao.Models.DTO;
using Zhao.Models.Entity;

namespace Zhao.IServer.Log
{
    /// <summary>
    /// 通知表（信息发布）
    ///</summary>
    public interface INotificationsServer : IBaseService<Notifications>
    {
        public Task<PageModel<NotificationDTO>> QueryNotiPageInfo(Expression<Func<Notifications, Venues, bool>> expressionable, int pageIndex, int pageSize);
        
        /// <summary>
        /// 获取最新的公告信息
        /// </summary>
        /// <param name="notificationType">公告类型：1-后台通知，5-用户通知</param>
        /// <param name="venueId">球馆ID，如果为null则查询平台通知</param>
        /// <returns>最新的公告信息</returns>
        Task<NotificationDTO> GetLatestNotification(short notificationType);
    }
}
